/* BoLe 智能HR系统样式 - 基于JH设计系统的统一风格 */

/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* 主题变量 - 与JH子系统保持一致 */
:root {
    /* 浅色主题 */
    --bg-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --bg-secondary: #ffffff;
    --bg-card: #ffffff;
    --bg-form: #ffffff;
    --bg-input: #ffffff;
    --text-primary: #333333;
    --text-secondary: #666666;
    --text-muted: #999999;
    --border-color: rgba(255, 255, 255, 0.2);
    --border-light: #e0e0e0;
    --shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
    --shadow-hover: 0 5px 30px rgba(102, 126, 234, 0.3);
    
    /* HR特色颜色 */
    --hr-primary: #667eea;
    --hr-secondary: #764ba2;
    --hr-success: #28a745;
    --hr-warning: #ffc107;
    --hr-danger: #dc3545;
    --hr-info: #17a2b8;
    
    /* 兼容旧变量命名 */
    --card-bg: var(--bg-card);
    --secondary-bg: var(--bg-secondary);
}

/* 深色主题 */
.dark-theme {
    --bg-primary: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    --bg-secondary: #2c3e50;
    --bg-card: #34495e;
    --bg-form: #34495e;
    --bg-input: #455a64;
    --text-primary: #ffffff;
    --text-secondary: #cccccc;
    --text-muted: #888888;
    --border-color: rgba(255, 255, 255, 0.1);
    --border-light: #444444;
    --shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
    --shadow-hover: 0 5px 30px rgba(52, 152, 219, 0.4);
    
    /* 深色主题HR颜色调整 */
    --hr-primary: #5dade2;
    --hr-secondary: #af7ac5;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: var(--bg-primary);
    min-height: 100vh;
    color: var(--text-primary);
    transition: all 0.3s ease;
    overflow-x: hidden;
}

/* 头部导航样式 */
.dashboard-header {
    background: var(--bg-secondary);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.header-left h1 {
    color: var(--hr-primary);
    font-size: 1.8rem;
    font-weight: 600;
}

.header-left h1 i {
    margin-right: 0.5rem;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.theme-controls {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-right: 1rem;
    padding-right: 1rem;
    border-right: 1px solid var(--border-light);
}

.theme-selector {
    padding: 0.5rem;
    border: 1px solid var(--border-light);
    border-radius: 4px;
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 0.9rem;
}

/* 按钮样式 */
.btn {
    padding: 0.6rem 1.2rem;
    border: none;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    white-space: nowrap;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: var(--shadow-hover);
}

.btn-primary {
    background: var(--hr-primary);
    color: white;
}

.btn-primary:hover {
    background: #5a6fd8;
}

.btn-secondary {
    background: var(--text-secondary);
    color: white;
}

.btn-secondary:hover {
    background: var(--text-primary);
}

.btn-success {
    background: var(--hr-success);
    color: white;
}

.btn-warning {
    background: var(--hr-warning);
    color: #212529;
}

.btn-danger {
    background: var(--hr-danger);
    color: white;
}

.btn-full {
    width: 100%;
    justify-content: center;
}

/* 主要内容布局 */
.main-content {
    display: flex;
    min-height: calc(100vh - 80px);
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1rem;
    gap: 1.5rem;
}

/* 侧边栏 */
.sidebar {
    width: 320px;
    background: var(--bg-card);
    border-radius: 12px;
    box-shadow: var(--shadow);
    margin: 1rem 0;
    height: fit-content;
    position: sticky;
    top: 100px;
    overflow-y: auto;
    max-height: calc(100vh - 120px);
}

.sidebar-header {
    background: var(--hr-primary);
    color: white;
    padding: 1.2rem;
    border-radius: 12px 12px 0 0;
    text-align: center;
}

.sidebar-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
}

/* AI聊天区域 */
.ai-chat-section {
    padding: 1.5rem;
    border-bottom: 1px solid var(--border-light);
}

.ai-chat-section h4 {
    color: var(--hr-primary);
    margin-bottom: 1rem;
    font-size: 1rem;
}

.chat-input-container {
    margin-bottom: 1rem;
}

.chat-input-container textarea {
    width: 100%;
    padding: 0.8rem;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    background: var(--bg-input);
    color: var(--text-primary);
    font-family: inherit;
    font-size: 0.9rem;
    resize: vertical;
    min-height: 80px;
    margin-bottom: 0.5rem;
}

.chat-input-container textarea:focus {
    outline: none;
    border-color: var(--hr-primary);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.chat-history {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid var(--border-light);
    border-radius: 8px;
    padding: 1rem;
    background: var(--bg-form);
}

.welcome-message {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.5;
}

.welcome-message i {
    color: var(--hr-primary);
    margin-right: 0.5rem;
}

.welcome-message ul {
    margin: 0.5rem 0;
    padding-left: 1.5rem;
}

.welcome-message li {
    margin-bottom: 0.3rem;
}

.chat-message {
    margin-bottom: 1rem;
    padding: 0.8rem;
    border-radius: 8px;
    max-width: 90%;
}

.chat-message.user {
    background: var(--hr-primary);
    color: white;
    margin-left: auto;
}

.chat-message.assistant {
    background: var(--border-light);
    color: var(--text-primary);
}

/* 筛选区域 */
.filter-section {
    padding: 1.5rem;
}

.filter-section h4 {
    color: var(--hr-primary);
    margin-bottom: 1rem;
    font-size: 1rem;
}

.filter-group {
    margin-bottom: 1rem;
}

.filter-group label {
    display: block;
    margin-bottom: 0.3rem;
    color: var(--text-secondary);
    font-size: 0.9rem;
    font-weight: 500;
}

.filter-group input,
.filter-group select {
    width: 100%;
    padding: 0.7rem;
    border: 2px solid var(--border-light);
    border-radius: 6px;
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 0.9rem;
}

.filter-group input:focus,
.filter-group select:focus {
    outline: none;
    border-color: var(--hr-primary);
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

/* 内容区域 */
.content-area {
    flex: 1;
    margin: 1rem 0;
}

/* 概览卡片 */
.overview-section {
    margin-bottom: 2rem;
}

.overview-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.overview-card {
    background: var(--bg-card);
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: var(--shadow);
    transition: all 0.3s ease;
    border: 1px solid var(--border-light);
}

.overview-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

.overview-card .card-header {
    display: flex;
    align-items: center;
    margin-bottom: 1rem;
}

.overview-card .card-header i {
    font-size: 1.5rem;
    color: var(--hr-primary);
    margin-right: 0.8rem;
}

.overview-card .card-header h3 {
    color: var(--text-secondary);
    font-size: 0.95rem;
    font-weight: 500;
}

.overview-card .card-value {
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--hr-primary);
    margin-bottom: 0.5rem;
}

.overview-card .card-description {
    color: var(--text-muted);
    font-size: 0.85rem;
}

/* 候选人区域 */
.candidates-section {
    background: var(--bg-card);
    border-radius: 12px;
    box-shadow: var(--shadow);
    overflow: hidden;
}

/* 标签页导航 */
.section-tabs {
    display: flex;
    background: var(--border-light);
    border-bottom: 1px solid var(--border-light);
}

.tab-button {
    flex: 1;
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.tab-button:hover {
    background: var(--bg-card);
    color: var(--text-primary);
}

.tab-button.active {
    background: var(--bg-card);
    color: var(--hr-primary);
    border-bottom: 3px solid var(--hr-primary);
}

/* 标签页内容 */
.tab-content {
    display: none;
    padding: 1.5rem;
}

.tab-content.active {
    display: block;
}

/* 候选人列表头部 */
.candidates-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-light);
}

.candidates-header h3 {
    color: var(--text-primary);
    font-size: 1.2rem;
}

.list-controls {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.sort-selector,
.candidate-selector {
    padding: 0.6rem 1rem;
    border: 2px solid var(--border-light);
    border-radius: 6px;
    background: var(--bg-input);
    color: var(--text-primary);
    font-size: 0.9rem;
    min-width: 150px;
}

/* 候选人列表 */
.candidates-list {
    min-height: 400px;
}

.loading-message {
    text-align: center;
    padding: 3rem;
    color: var(--text-muted);
    font-size: 1.1rem;
}

.loading-message i {
    display: block;
    font-size: 2rem;
    margin-bottom: 1rem;
    color: var(--hr-primary);
}

.candidate-card {
    background: var(--bg-form);
    border: 2px solid var(--border-light);
    border-radius: 10px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    cursor: pointer;
}

.candidate-card:hover {
    border-color: var(--hr-primary);
    box-shadow: var(--shadow-hover);
    transform: translateY(-1px);
}

.candidate-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.candidate-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.candidate-match-score {
    background: var(--hr-primary);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.candidate-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.candidate-detail {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.candidate-detail i {
    color: var(--hr-primary);
    width: 16px;
    text-align: center;
}

.candidate-skills {
    margin-top: 1rem;
}

.candidate-skills-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.skills-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.skill-tag {
    background: var(--border-light);
    color: var(--text-secondary);
    padding: 0.2rem 0.6rem;
    border-radius: 12px;
    font-size: 0.8rem;
}

/* 图表网格 */
.charts-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
    gap: 1.5rem;
}

.chart-card {
    background: var(--bg-form);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.chart-card:hover {
    box-shadow: var(--shadow-hover);
}

.chart-header {
    background: var(--border-light);
    padding: 1rem 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid var(--border-light);
}

.chart-header h4 {
    color: var(--text-primary);
    font-size: 1rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.chart-header i {
    color: var(--hr-primary);
}

.chart-expand-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1rem;
    cursor: pointer;
    padding: 0.3rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.chart-expand-btn:hover {
    background: var(--bg-card);
    color: var(--hr-primary);
}

.chart-container {
    padding: 1.5rem;
    min-height: 300px;
    position: relative;
}

/* 深度分析区域 */
.deep-analysis-container {
    min-height: 500px;
}

.analysis-selector {
    background: var(--bg-form);
    padding: 1.5rem;
    border-radius: 10px;
    border: 1px solid var(--border-light);
    margin-bottom: 1.5rem;
}

.analysis-selector h4 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-size: 1rem;
}

.deep-analysis-result {
    background: var(--bg-form);
    border: 1px solid var(--border-light);
    border-radius: 10px;
    min-height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.placeholder-message {
    text-align: center;
    color: var(--text-muted);
    padding: 2rem;
}

.placeholder-message i {
    font-size: 3rem;
    margin-bottom: 1rem;
    display: block;
    color: var(--hr-primary);
}

.placeholder-message p {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
}

.sub-text {
    font-size: 0.9rem;
    color: var(--text-muted);
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.chart-modal-content,
.candidate-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: var(--bg-card);
    border-radius: 12px;
    box-shadow: 0 10px 50px rgba(0, 0, 0, 0.3);
    max-width: 90vw;
    max-height: 90vh;
    overflow: auto;
}

.chart-modal-content {
    width: 800px;
    height: 600px;
}

.candidate-modal-content {
    width: 700px;
    min-height: 500px;
}

.chart-modal-header,
.candidate-modal-header {
    background: var(--hr-primary);
    color: white;
    padding: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 12px 12px 0 0;
}

.modal-close {
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.1);
}

.chart-modal-body {
    padding: 2rem;
    height: calc(600px - 80px);
}

.candidate-modal-body {
    padding: 1.5rem;
    max-height: 400px;
    overflow-y: auto;
}

.candidate-modal-footer {
    padding: 1.5rem;
    border-top: 1px solid var(--border-light);
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* 分页控件 */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.5rem;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border-light);
}

.pagination-btn {
    padding: 0.5rem 0.8rem;
    border: 1px solid var(--border-light);
    background: var(--bg-card);
    color: var(--text-secondary);
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.pagination-btn:hover:not(.disabled) {
    background: var(--hr-primary);
    color: white;
    border-color: var(--hr-primary);
}

.pagination-btn.active {
    background: var(--hr-primary);
    color: white;
    border-color: var(--hr-primary);
}

.pagination-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.pagination-info {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 0 1rem;
}

/* 加载指示器 */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 3000;
}

.loading-spinner {
    background: var(--bg-card);
    padding: 2rem 3rem;
    border-radius: 12px;
    text-align: center;
    color: var(--text-primary);
}

.loading-spinner i {
    font-size: 2rem;
    color: var(--hr-primary);
    margin-bottom: 1rem;
}

/* Toast 通知 */
.toast {
    position: fixed;
    top: 100px;
    right: 20px;
    background: var(--bg-card);
    color: var(--text-primary);
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: var(--shadow-hover);
    z-index: 2500;
    transform: translateX(400px);
    transition: transform 0.3s ease;
    max-width: 400px;
}

.toast.show {
    transform: translateX(0);
}

.toast-content {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.toast-content i {
    font-size: 1.2rem;
}

.toast.success .toast-content i {
    color: var(--hr-success);
}

.toast.error .toast-content i {
    color: var(--hr-danger);
}

.toast.warning .toast-content i {
    color: var(--hr-warning);
}

.toast.info .toast-content i {
    color: var(--hr-info);
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .main-content {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
        position: static;
        margin: 1rem 0;
        max-height: none;
    }
    
    .charts-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .header-content {
        flex-direction: column;
        gap: 1rem;
    }
    
    .overview-cards {
        grid-template-columns: repeat(2, 1fr);
        gap: 1rem;
    }
    
    .candidate-details {
        grid-template-columns: 1fr;
    }
    
    .chart-modal-content,
    .candidate-modal-content {
        width: 95vw;
        height: 95vh;
        margin: 0;
    }
    
    .section-tabs {
        flex-wrap: wrap;
    }
    
    .tab-button {
        flex: 1 1 auto;
        min-width: 120px;
    }
}

@media (max-width: 480px) {
    .overview-cards {
        grid-template-columns: 1fr;
    }
    
    .list-controls {
        flex-direction: column;
        align-items: stretch;
        gap: 0.5rem;
    }
    
    .candidate-card-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
    
    .candidate-modal-footer {
        flex-direction: column;
    }
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease;
}

.slide-in {
    animation: slideIn 0.3s ease;
}

/* 滚动条美化 */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--border-light);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: var(--hr-primary);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--hr-secondary);
}

/* 表单验证状态 */
.form-group.error input,
.form-group.error textarea,
.form-group.error select {
    border-color: var(--hr-danger);
}

.form-group.success input,
.form-group.success textarea,
.form-group.success select {
    border-color: var(--hr-success);
}

.error-message {
    color: var(--hr-danger);
    font-size: 0.8rem;
    margin-top: 0.3rem;
}

.success-message {
    color: var(--hr-success);
    font-size: 0.8rem;
    margin-top: 0.3rem;
}


















